<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html lang="zh">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>运营管理平台 - 顶十</title>
<%@include file="../include/imports.jsp"%>
<script src="/assets/js/jquery-form.js"></script>
<script src="/assets/js/manager/jqutils.js"></script>
<script src="/assets/js/manager/proprietary.js"></script>
</head>
<style>
.input-box {
	display: block;
	margin-left: 50px;
}

.input-box .form-control {
	width: 380px;
}
</style>
<body style="overflow: auto;">
	<div class="navbar" role="navigation">
		<%@include file="../include/top.jsp"%>
	</div>
	<div class="container-fluid content">
		<div class="row">
			<%@include file="../include/menu.jsp"%>
			<div class="main">
				<div class="row">
					<div class="col-lg-12">
						<ol class="breadcrumb">
							<li><i class="fa fa-home"></i><a href="index.do">首页</a></li>
							<li><i class="fa fa-laptop"></i><span>自营店管理</span></li>
						</ol>
					</div>
				</div>
				<div class="row toolbox">
					<input type="button" id="lookUser" class="btn btn-sm btn-success"
						value="关联账户"> <input type="button" id="updatePwd"
						class="btn btn-sm btn-warning" value="修改密码">
				</div>
				<div class="row">
					<div class="col-md-12">
						<div class="panel panel-default">
							<form id="myForm" action="" method="post"
								enctype="multipart/form-data" class="form-horizontal ">
								<input type="hidden" id="uuid" name="uuid" value="${shop.uuid }">
								<div class="panel-body">
									<div class="form-group">
										<label class="col-md-1 control-label">商店名称</label>
										<div class="col-md-3">
											<input type="text" id="name" name="name" class="form-control"
												value="${shop.name }"
												<c:if test="${shop.name !=null}">readonly</c:if>
												placeholder="例：Top10自营" must> <span class="help-block"></span>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="contacts">联系人</label>
										<div class="col-md-3">
											<input type="text" id="contacts" name="contacts"
												class="form-control" value="${shop.contacts }"
												placeholder="例：林总" must="name"> <span
												class="help-block"></span>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="email">电子邮箱
										</label>
										<div class="col-md-3">
											<input type="email" id="email" name="email"
												class="form-control" value="${shop.email }"
												placeholder="例：11111@qq.com" must="email"> <span
												class="help-block"></span>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="telephone">联系电话</label>
										<div class="col-md-3">
											<input type="text" id="telephone" name="telephone"
												class="form-control" value="${shop.telephone }"
												placeholder="例：0755-1234567" must="tel"> <span
												class="help-block"></span>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="cellphone">联系手机
										</label>
										<div class="col-md-3">
											<input type="text" id="cellphone" name="cellphone"
												class="form-control" value="${shop.cellphone }"
												placeholder="例：13123456789" must="phone">
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="province">地区
										</label>
										<div class="col-md-3">
											<input type="hidden" id="province" name="province"
												value="${shop.province }"> <input type="hidden"
												id="city" name="city" value="${shop.city }"> <input
												type="hidden" id="district" name="district"
												value="${shop.district }"> <span id="list3"
												class="form-control" style="padding: 0;"><span
												id="store-selector"></span></span>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">街道
										</label>
										<div class="col-md-3">
											<input type="text" id="street" name="street"
												class="form-control" value="${shop.street }">
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">详细地址
										</label>
										<div class="col-md-3">
											<input type="text" id="detailed_address"
												name="detailed_address" class="form-control"
												value="${shop.detailed_address }" must>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">身份证
										</label>
										<div class="col-md-3">
											<input type="text" id="idcard_number" name="idcard_number"
												class="form-control" value="${shop.idcard_number }"
												placeholder="例：440822222222222222" must="idcard">
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">LOGO
										</label>
										<div class="col-md-3">
											<div class="controls">
												<div class="fileupload fileupload-new data-provides">
													<div class="fileupload-new thumbnail"
														style="width: 200px; height: 150px;">
														<img src="${home}${shop.logo }?num=${num}" alt=""
															id="logo" />
													</div>
													<div
														class="form-control fileupload-preview fileupload-exists thumbnail"
														style="width: 380px; height: 200px; padding: 0;"></div>
													<div id="uploadimg">
														<input type="file" name="logoi" id="logoi"
															style="display: none;"
															<c:if test="${shop.logo ==null}"> must="picture" show="#t_head"</c:if> />
														<label for="logoi"
															class="fileupload-new btn btn-sm btn-success"
															style="margin: 0">选择文件</label> <label for="logoi"
															class="fileupload-exists btn btn-sm btn-success"
															style="margin: 0">更改</label> <span
															class="fileupload-exists data-dismiss btn btn-sm btn-danger">移除</span>
													</div>
												</div>
											</div>
										</div>
									</div>
									<%-- <div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">身份证
										</label>
										<div class="col-md-3">
											<div class="controls">
												<div class="fileupload fileupload-new data-provides">
													<div class="fileupload-new thumbnail"
														style="width: 200px; height: 150px;">
														<img src="${home}${shop.idcard }?num=${num}" alt=""
															id="idcard" />
													</div>
													<div
														class="form-control fileupload-preview fileupload-exists thumbnail"
														style="width: 380px; height: 200px; padding: 0;"></div>
													<div id="uploadimg">
														<input type="file" name="sfz" id="sfz"
															style="display: none;" /> <label for="sfz"
															class="fileupload-new btn btn-sm btn-success"
															style="margin: 0">选择文件</label> <label for="sfz"
															class="fileupload-exists btn btn-sm btn-success"
															style="margin: 0">更改</label> <span
															class="fileupload-exists data-dismiss btn btn-sm btn-danger">移除</span>
													</div>
												</div>
											</div>
										</div>
									</div> --%>
									<%-- <div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">营业执照
										</label>
										<div class="col-md-3">
											<div class="controls">
												<div class="fileupload fileupload-new data-provides">
													<div class="fileupload-new thumbnail"
														style="width: 200px; height: 150px;">
														<img src="${home}${shop.business_licence }?num=${num}"
															alt="" id="business_licence" />
													</div>
													<div
														class="form-control fileupload-preview fileupload-exists thumbnail"
														style="width: 380px; height: 200px; padding: 0;"></div>
													<div id="uploadimg">
														<input type="file" name="yyzz" id="yyzz"
															style="display: none;" /> <label for="yyzz"
															class="fileupload-new btn btn-sm btn-success"
															style="margin: 0">选择文件</label> <label for="yyzz"
															class="fileupload-exists btn btn-sm btn-success"
															style="margin: 0">更改</label> <span
															class="fileupload-exists data-dismiss btn btn-sm btn-danger">移除</span>
													</div>
												</div>
											</div>
										</div>
									</div> --%>
									<%-- <div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">开户人
										</label>
										<div class="col-md-3">
											<input type="text" id="account_holder" name="account_holder"
												class="form-control" 
												value="${shop.account_holder }" must="name">
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">银行名称
										</label>
										<div class="col-md-3">
											<input type="text" id="bank_name" name="bank_name"
												class="form-control" 
												value="${shop.bank_name }" must="ch_en_num_un">
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">银行账户
										</label>
										<div class="col-md-3">
											<input type="text" id="bank_account" name="bank_account"
												class="form-control" 
												value="${shop.bank_account }" must="only_num">
										</div>
									</div> --%>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">支付宝账户
										</label>
										<div class="col-md-3">
											<input type="text" id="alipay" name="alipay"
												class="form-control" value="${shop.alipay }" must="only_num">
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="disabled-input">本店介绍
										</label>
										<div class="col-md-3">
											<textarea id="description" name="description" rows="9"
												class="form-control" must>${shop.description }</textarea>
										</div>
									</div>
									<div class="form-group">
										<label class="col-md-1 control-label" for="textarea-input">本店承诺</label>
										<div class="col-md-3">
											<textarea id="promise" name="promise" rows="9"
												class="form-control" must>${shop.promise }</textarea>
										</div>
									</div>

									<br>

								</div>
								<div class="panel-footer">
									<button type="button" id="submit"
										class="btn btn-sm btn-success">
										<i class="fa fa-dot-circle-o"></i> 提交
									</button>
								</div>
							</form>
						</div>
					</div>
				</div>
				<div id="user_content" style="display: none;">
					<form id="userForm" class="form" method="post"
						enctype="multipart/form-data" style="padding-left: 10px;">
						<div class="form-group">
							<label class=" control-label" for="account">账号 </label> <input
								type="text" id="account" name="account" class="form-control"
								placeholder="账号" value="${user.account }" must
								<c:if test="${user.account !=null}">readonly="readonly"</c:if> />
						</div>
						<div class="form-group">
							<label class=" control-label" for="nickname">昵称 </label> <input
								type="text" id="nickname" name="nickname" class="form-control"
								placeholder="昵称" value="${user.nickname }" must />
						</div>
						<div class="form-group">
							<label class=" control-label" for="cellphone">手机 </label> <input
								type="text" id="cellphone2" name="cellphone"
								class="form-control" placeholder="手机" value="${user.cellphone }"
								must="phone" />
						</div>
						<div class="form-group">
							<label class=" control-label" for="sex">性别</label> <select
								id="sex" name="sex" class="form-control">
								<option value="1">男</option>
								<option value="0">女</option>
							</select>
						</div>
						<div class="form-group">
							<label class=" control-label" for="head_sculpture">头像</label>
							<div class="fileupload fileupload-new data-provides"
								style="display: inline-block; vertical-align: middle;">
								<div id="t_head" class="form-control fileupload-new thumbnail"
									style="width: 200px; height: 200px; padding: 0; line-height: 200px;">
									<img id="head_sculpture" name="head_sculpture"
										src="${home }${user.head_sculpture }" />
								</div>
								<div
									class="form-control fileupload-preview fileupload-exists thumbnail"
									style="width: 380px; height: 200px; padding: 0;"></div>
								<div id="uploadimg">
									<input type="hidden" name="head" /> <input type="file"
										name="head" id="head" style="display: none;"
										<c:if test="${user.head_sculpture ==null}">must="picture" show="#t_head"</c:if> />
									<label for="head" class="fileupload-new btn btn-sm btn-success"
										style="margin: 0">选择文件</label> <label for="head"
										class="fileupload-exists btn btn-sm btn-success"
										style="margin: 0">更改</label> <span
										class="fileupload-exists data-dismiss btn btn-sm btn-danger">移除</span>
								</div>
							</div>
						</div>
					</form>
					<div class="form"
						style="width: 100%; background-color: #ddd; text-align: right; bottom: 0px; position: fixed;">
						<input id="submit_user" type="button"
							class="btn btn-sm btn-success" value="保存" />
					</div>
				</div>
				<div id="pwd_content" style="display: none;">
					<form id="pwdForm" class="form" method="post"
						enctype="multipart/form-data" style="padding-left: 10px;">
						<div class="form-group">
							<label class=" control-label" for="password">输入密码 </label> <input
								type="password" id="password" name="password"
								class="form-control" placeholder="输入密码" value="" must />
						</div>
						<div class="form-group">
							<label class=" control-label" for="password2">确认密码 </label> <input
								type="password" id="password2" name="password2"
								class="form-control" placeholder="确认密码" value="" must />
						</div>
					</form>
					<div class="form"
						style="width: 100%; background-color: #ddd; text-align: right; bottom: 0px; position: fixed;">
						<input id="submit_pwd" type="button"
							class="btn btn-sm btn-success" value="保存" />
					</div>
				</div>
			</div>
		</div>
	</div>
	<%@include file="../include/modal.jsp"%>
	<div class="clearfix"></div>
</body>
</html>